<template>
  <view class="tips-card">
		<view class="tips-photo">
			<image :src="photo" mode="widthFix"></image>
		</view>
		<view class="tips-info">
			<view class="tips-title">
				{{title}}
			</view>
			<view class="tips-time">
				<!-- 2020-11-21 12:12:12 -->
				{{time}}
			</view>
		</view>
  </view>
</template>

<script>
import {uniList, uniListItem} from '@dcloudio/uni-ui'
export default {
	name: 'tips-card',
	props: ['title', 'time', 'photo'],
	components: {
		uniList, uniListItem
	}
}
</script>

<style lang='scss'>
.tips-card {
	padding: 10px;
	height: 100px;
	width: 100%;
	display: flex;
	border-bottom: 1px dotted #f5f5f5;
	box-sizing: border-box;
	.tips-info {
		width: 60%;
		height: 80px;
		display: flex;
		flex-direction: column;
		padding: 0 10px;
		justify-content: space-between;
		.tips-title {
			font-size: 14px;
			font-weight: normal;
			color: #333;
			display: -webkit-box;
			-webkit-box-orient: vertical;
			-webkit-line-clamp: 2; 	//行数
			overflow: hidden;
		}
		.tips-time{
			font-size: 12px;
			color: #999999;
		}
	}
	.tips-photo {
		width: 40%;
		height: 80px;
		overflow: hidden;
		border-radius: 10px;
		image {
			width: 100%;
			height: 100%;
		}
	}
}
</style>